import {createRouter, createWebHashHistory} from 'vue-router'

const routes = [
    {
        path: "/login",
        name: "login",
        component: ()=> import("../viwes/login/index.vue")
    },
    {
        path: "/",
        name: "layout",
        component: ()=> import("../viwes/layout/index.vue"),
        children: [
            {
                path: "",
                name: "home",
                component: ()=> import("../viwes/home/index.vue"),
            },
            {
                path: "/my",
                name: "my",
                component: ()=> import("../viwes/my/index.vue"),
            },
            {
                path: "/setting",
                name: "setting",
                component: ()=> import("../viwes/setting/index.vue"),
            },
        ]
    },
]

const router = createRouter({
    history: createWebHashHistory(),
    routes
})

export default router;